namespace JHT.EFMigrationTest.ClassLibrary1.Migrations
{
    using System;
    using System.Data.Entity.Migrations;
    
    public partial class addSutdentClassView : DbMigration
    {
        public override void Up()
        {
            Sql(" create view View_View_StudentClass as select S.Id As StudentId, S.StudentName, C.Id As ClassId, c.ClassName from Students as S left join ClassInfo as C on S.AssignedClassId = c.Id");
        }
        
        public override void Down()
        {
          
            Sql("drop view dbo.View_StudentClass");
        }
    }
}
